1. Technical Field
The present invention relates to an optical reading device that conveys and optically reads a medium, to a method of controlling the optical reading device, and to a program.
2. Related Art
Optical reading devices such as scanners that are connected to a host computer convey a document (medium), temporarily store the image data captured from the conveyed medium in a buffer (a storage unit), and after scanning the document is completed, send the scanned data stored in the buffer to the host computer. See, for example, Japanese Unexamined Patent Appl. Pub. JP-A-2009-284191.
However, when the scanned data cannot be sent because of a problem on the host computer side (such as when the image processing capacity of the host computer cannot keep up), the scanned data is particularly large, or the scanning speed of the scanner is faster than the data transmission speed to the host computer, the buffer may become full. As a result, the scanner must pause scanning and conveying the document (or moving the scanner). In addition, depending upon how the buffer is used, buffer capacity may be insufficient or buffered data may be overwritten with newly scanned data even though the buffer is used to full capacity, and some scanned data may be lost.
Before or when the buffer capacity is exhausted in the related art, scanning is paused and a standby mode is entered. When sending the scanned data from the buffer to the host computer resumes or when a sufficient amount of data is transmitted so that there is sufficient buffer capacity again, scanning then resumes to acquire data for the remaining portion of the document.
A problem with this configuration, however, is that scanning accuracy may drop as a result of how precisely conveying the document can be stopped and restarted when scanning is paused and then resumed. This problem is not limited to when scanning is paused, and also occurs at the beginning and end of normal document scanning.
More specifically, image shifting occurs near where scanning was paused when scanning resumes. This image shift is further described below. Due to inertia, gear backlash, or roller deformation, for example, there is a delay between when driving the paper feed motor, for example, starts and when the rollers that convey the actual document start working, creating a period in which the document is not actually conveyed, and resulting in scanned data being captured from the same position where the document is not conveyed even though scanning is synchronized to the transportation motor. When the transportation motor, for example, is stopped, the rollers that convey the actual document cannot respond immediately for the same reasons, resulting in the document continuing to be actually conveyed, and if scanning continues during this time, the scanned data can be captured as normal scanning data.